<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>书籍详情页</title>
<meta name="keywords"
	content="Book Store Template, Free CSS Template, CSS Website Layout, CSS, HTML, cssMoban.com" />
<meta name="description"
	content="Book Store Template, Free CSS Template, Download CSS Website from cssMoban.com" />
<link href="templatemo_style.css" rel="stylesheet" type="text/css" />
</head>
<body>
	<!--  网站模板 from www.cssmoban.com -->
	<div id="templatemo_container">
		<div id="templatemo_menu">
			<ul>
				<c:if test="${user!=null }">
				<li><a href="#" class="current">欢迎进入图书管理系统:</a></li> 
					<li><a href="#" class="current">${user.user_name}</a></li>
					<li><a href="UserInfoServlet?opr=outlog" class="current">&nbsp;&nbsp;&nbsp;登录注销</a></li>
					
				</c:if>
				<c:if test="${user==null }">
				<li><a href="#" class="current">欢迎进入图书管理系统:</a></li>
					<li><a href="login.jsp" class="current">游客访问,请登录或注册...</a></li>
				</c:if>
			</ul>
		</div>
		<!-- end of menu -->


		<div id="templatemo_content">

			<div id="templatemo_content_left">

				<div class="templatemo_content_left_section">
					<h1>书籍列表</h1>
					<ul>
						<c:forEach items="${books }" var="b">
							<li><a
								href="UserInfoServlet?opr=detailsbooks&detailsbooksbookid=${b.id }">${b.book_number }</a></li>
						</c:forEach>
					</ul>
				</div>

			</div>
			<!-- end of content left -->

			<div id="templatemo_content_right">

				<h1>${bookdetails.book_number }
					<span>(${bookdetails.book_user_name })</span>
				</h1>
				<div class="image_panel">
					<img src="${bookdetails.book_imgurl }" alt="CSS Template"
						width="100" height="150" />
				</div>
				<ul>
					<li>${bookdetails.book_date }</li>
					<li>书刊号:${bookdetails.book_phone}</li>
				</ul>
				<p>${bookdetails.book_dateails}</p>
				<div class="cleaner_with_height">&nbsp;</div>
				<div>
					<ul>
						<li>评论:</li>
					</ul>
					<c:if test="${user!=null }">
					<form action="UserInfoServlet?opr=addcomment" method="post">
						<textarea rows="5" cols="75" name="msg"></textarea>
						<input type="hidden" name="book_key" value="${bookdetails.id }"/>
						<input type="hidden" name="name" value="${user.user_name }"/>
						<br /> <input align="right" type="submit" value="提交评论" />
					</form>
					</c:if>
				</div>
				<div>
					<c:forEach items="${comments }" var="comment">
						<hr style="height:1px;border:none;border-top:1px solid #555555;" />

						<div align="right">
							<p>${comment.msg }</p>
							评论人:${comment.name },评论时间:${comment.commentdate }
						</div>
					</c:forEach>

				</div>
			</div>
			<!-- end of content right -->

			<div class="cleaner_with_height">&nbsp;</div>
		</div>
		<!-- end of content -->

	</div>
</body>
</html>